package cn.yunlang.zhangZhongFei.entity;

import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.annotation.JsonIgnore;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import java.io.Serializable;
import java.util.Date;
import lombok.Data;

/**
 * 抽检消息记录表
 *
 * @author ·
 * @since 2025-05-27 14:23:39
 */
@Data
@TableName("t_award_message")
@ApiModel(value = "AwardMessage对象", description = "抽奖消息记录表")
public class AwardMessage implements Serializable {

  private static final long serialVersionUID = 1L;

  @ApiModelProperty(value = "id", hidden = true)
  @TableId(value = "id", type = IdType.AUTO)
  private Long id;

  @ApiModelProperty("发消息者id")
  @TableField("user_id")
  private Long userId;

  @ApiModelProperty("奖品id")
  @TableField("award_id")
  @JsonIgnore
  private Long awardId;

  @ApiModelProperty("消息正文")
  @TableField("text")
  private String text;

  @ApiModelProperty("创建时间")
  @TableField(value = "create_time", fill = FieldFill.INSERT)
  @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
  private Date createTime;
}
